/********************************************************************************
 *      Copyright:  (C) 2022 Zhang xiangyun<1327295677@qq.com>
 *                  All rights reserved.
 *
 *       Filename:  mqtt.h
 *    Description:  This head file 
 *
 *        Version:  1.0.0(20/05/22)
 *         Author:  Zhang xiangyun <1327295677@qq.com>
 *      ChangeLog:  1, Release initial version on "20/05/22 20:25:44"
 *                 
 ********************************************************************************/
#ifndef _MQTT_H_
#define _MQTT_H_

#define SIZE 512
typedef struct mosquitto_s 
{
	char       host[SIZE];
	char       topic[SIZE];
	char       clientid[SIZE];
	char       username[SIZE];
	char       password[SIZE];
}mosquitto_t;

//extern void connect_pub_callback(struct mosquitto *mosq,void *obj,int rc);
extern int mqtt_connect(mosquitto_t mos_msg);
extern int mqtt_pub(char *p,mosquitto_t mos_msg);

extern struct mosquitto *mosq;
#endif 


